<?php
	defined('_JEXEC')or die('Restricted Access');
	//importando el contollador base
	 
	require_once(JPATH_COMPONENT.DS.'controller.php');
	require_once( JPATH_COMPONENT_ADMINISTRATOR.DS.'helpers'.DS.'toolbar.php');
	
	if($controller = JRequest::getWord('controller')){
		$path = JPATH_COMPONENT.DS.'controller'.DS.$controller.'.php';
		if(file_exists($path)){
			require_once $path;
		}else{
		  	$controller = "";
		}
	}
	$classname = 'ContratosController'.$controller;
	$controller = new $classname();
	//$controller->execute(JRequest::getVar('task'));
	$controller->execute('');
	$controller->redirect();
?>